<template>
  <div class="scroll" @scroll.passive="handleScroll">
    <slot/>
  </div>
</template>

<script>
export default {
  name: 'scroll',
  methods: {
    handleScroll (e) {
      console.log(e.target.scrollTop)
    }
  }
}
</script>

<style scoped lang="less">
.scroll {
  width: 100%;
  height: 100%;
  overflow-x: hidden;
  overflow-y: scroll;

  &::-webkit-scrollbar {
    display: none;
  }
}
</style>
